Imports System.Data.OracleClient

Public Class tticccll

  Public pvin_ctrl_srno As Integer
  Public pvst_form_idnt As String
  Public pvst_ctrl_idnt As String
  Public pvst_prnt_ctrl_idnt As String
  Protected mCmdData As OracleCommand
  Protected mDrData As OracleDataReader
  '-----------------------------------------------------------------------


  Public Sub pvvd_ftch _
            (ByVal aDrDataReader As OracleDataReader)

    'Dim lvbl_data_exst_cndn As Boolean

    ' orbl_ftch_endx_cndn = False

    'tvvd_ftch_data_exst_cndn _
    ' (lvbl_data_exst_cndn)

    If aDrDataReader.HasRows = True Then

      mPrFtchData(aDrDataReader)

      '  orbl_ftch_endx_cndn = False

    Else

      ' orbl_ftch_endx_cndn = True

    End If

  End Sub


  '-----------------------------------------------------------------------


  Private Sub mPrFtchData(ByVal aDrDataReader As OracleDataReader)

    aDrDataReader.Read()
    pvin_ctrl_srno = aDrDataReader("TFCC_CTRL_SRNO")

    pvst_form_idnt = aDrDataReader("TFCC_form_idnt")

    pvst_ctrl_idnt = aDrDataReader("TFCC_ctrl_idnt")

    pvst_prnt_ctrl_idnt = aDrDataReader("TFCC_prnt_ctrl_idnt")


  End Sub


  '-----------------------------------------------------------------------


  Public Sub pvvd_selc _
              (ByRef orbl_data_exst_cndn As Boolean)

    Dim lrbl_data_exst_cndn As Boolean

    tvvd_selc(lrbl_data_exst_cndn)

    orbl_data_exst_cndn = lrbl_data_exst_cndn

  End Sub


  '-----------------------------------------------------------------------


  Protected Sub tvvd_selc _
                  (ByRef irbl_data_exst_cndn As Boolean)

    Dim lvbl_retn_cndn As Boolean
    Dim lvst_sqlx_strn As String

    lvst_sqlx_strn = _
      "select TFCC_ctrl_srno           " & _
            ",TFCC_form_idnt           " & _
            ",TFCC_ctrl_idnt           " & _
            ",TFCC_prnt_ctrl_idnt      " & _
      "from  TRDX_FORM_CHLD_CTRL       " & _
      "where TFCC_form_idnt   =       '" & pvst_form_idnt & "' " & _
      " and TFCC_prnt_ctrl_idnt =     '" & pvst_prnt_ctrl_idnt & "'" & _
      "order by TFCC_ctrl_srno       "



    'tvvd_exec_qury _
    '  (lvst_sqlx_strn)


    'tvvd_ftch_data_exst_cndn _
    ' (lvbl_retn_cndn)

    mCmdData = New OracleCommand(lvst_sqlx_strn, con)
    mDrData = mCmdData.ExecuteReader

    If mDrData.HasRows = True Then

      mPrFtchData(mDrData)

    Else

      lvbl_retn_cndn = False

    End If

    irbl_data_exst_cndn = lvbl_retn_cndn


  End Sub


  '-----------------------------------------------------------------------


  Public Sub pvvd_rtrv_allx()

    tvvd_rtrv_allx()

  End Sub


  '-----------------------------------------------------------------------


  Protected Sub tvvd_rtrv_allx()

    Dim lvst_sqlx_strn As String

    lvst_sqlx_strn = _
      "select TFCC_ctrl_srno           " & _
            ",TFCC_form_idnt           " & _
            ",TFCC_ctrl_idnt           " & _
            ",TFCC_prnt_ctrl_idnt      " & _
      "from  TRDX_FORM_CHLD_CTRL       " & _
      "order by TFCC_ctrl_srno         "

    'tvvd_exec_qury _
    '  (lvst_sqlx_strn)

    mCmdData = New OracleCommand(lvst_sqlx_strn, con)
    mDrData = mCmdData.ExecuteReader

  End Sub


  '-----------------------------------------------------------------------


  Sub New()

    rvvd_init()

  End Sub


  '-----------------------------------------------------------------------


  Private Sub rvvd_init()

    pvin_ctrl_srno = 0
    pvst_form_idnt = ""
    pvst_ctrl_idnt = ""

  End Sub

End Class
